// Author: wsfuyibing <682805@qq.com>
// Date: 2025-07-04

package kind

import "encoding/json"

// LinkParams
// 链接参数
type LinkParams map[string]any

func NewLinkParams() LinkParams {
	return make(LinkParams)
}

func (o LinkParams) Set(key string, value any) LinkParams {
	o[key] = value
	return o
}

func (o LinkParams) String() string {
	if buf, err := json.Marshal(o); err == nil {
		return string(buf)
	}
	return "{}"
}
